import { createStackNavigator } from 'react-navigation'
import Person from './person'
import Photo from '../photo/photo'

const RootStack = createStackNavigator({
  Person: {
    screen: Person,
    navigationOptions: {
      header : null
    }
  },
  Photo
})
RootStack.navigationOptions = ({ navigation }) => {
  let tabBarVisible = true;
  if (navigation.state.index > 0) {
    tabBarVisible = false;
  }

  return {
    tabBarVisible,
  };
}
export default RootStack
